#pragma once
struct Vector2
{
	float x, y;

	Vector2();
	Vector2(float x, float y);
	Vector2(float value);

	friend Vector2 operator+(const Vector2& left, const Vector2& right);
	friend Vector2 operator-(const Vector2& left, const Vector2& right);

	friend Vector2 operator*(const float& value, const Vector2& right);
	friend Vector2 operator*(const Vector2& left, const float& value);
	friend float operator*(const Vector2& left, const Vector2& right);

	const Vector2& operator+=(const Vector2& right);
	const Vector2& operator-=(const Vector2& right);
	const Vector2& operator*=(const float& right);

	float SquareLength() const;
	float Length() const;

	static Vector2 Normalize(const Vector2& vec);
	static float Dot(const Vector2& left, const Vector2& right);
};


